<template>
  <el-container class="layout">
    <!-- 顶部 Header -->
    <el-header class="header">
      <div class="header-content">
        <div class="logo">🚗manage docker</div>
      </div>
    </el-header>

    <!-- 主体区域 -->
    <el-container class="body-container">
      <!-- 左侧 Aside -->
      <el-aside width="200px" class="sidebar">
        <el-menu :default-active="$route.path" class="el-menu-vertical-demo" router>

          <el-menu-item index="/ImagesManage">
            <el-icon :size="30"><MessageBox /></el-icon>
            {{$t("dockerimages.title")}}</el-menu-item>
          
          <el-menu-item index="/ContainerManage">
            <el-icon :size="30"><Management /></el-icon>
            {{$t("dockerContainers.title")}}</el-menu-item>

          <el-menu-item index="/settings">
            <el-icon :size="30"><Setting /></el-icon>
            {{$t("settings.title")}}
          </el-menu-item>
        </el-menu>
      </el-aside>

      <!-- 右侧 Main -->
      <el-main class="main-content">
        <router-view />
      </el-main>
    </el-container>
  </el-container>
</template>

<script setup lang="ts">

</script>

<style>
html, body, #app {
  margin: 0;
  padding: 0;
  height: 100%;
  width: 100%;
}

.layout {
  height: 100vh;
  width: 100vw;
  display: flex;
  flex-direction: column;
}

.header {
  background-color: #a5c0df;
  color: #333;
  height: 60px;
  display: flex;
  align-items: center;
  padding: 0 20px;
  font-size: 18px;
  font-weight: bold;
}

.body-container {
  flex: 1;
  display: flex;
}

.sidebar {
  background-color: #d6eaff;
}

.main-content {
  background-color: #f0f6ff;
  flex: 1;
  padding: 20px;
}

.el-menu-item a {
  text-decoration: none;
  color: inherit;
  display: block;
  width: 100%;

}
</style>
